package OJDemo输入输出;

import java.util.Arrays;
import java.util.Scanner;

/**
 * @author zc
 * @version 1.0
 * @date 2021/9/7 13:29
 */
public class Main9 {
    public static void main(String[] args) {
        Scanner cin = new Scanner(System.in);


        int n = cin.nextInt();

        String[] strings = new String[n];
        for (int i = 0; i < n; i++) {
            strings[i] = cin.next();
        }

        Arrays.sort(strings);
        for (int i = 0; i < n; i++) {
            System.out.print(strings[i]+" ");
        }

    }
}
